<html>
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
    <title>spones</title>
  </head>
  <body bgcolor="#FFFFFF">
    <center>Scilab Function</center>
    <div align="right">Last update : January 1995</div>
    <p>
      <b>spones</b> -   sparse matrix</p>
    <h3>
      <font color="blue">Calling Sequence</font>
    </h3>
    <dl>
      <dd>
        <tt>sp=spones(A)  </tt>
      </dd>
    </dl>
    <h3>
      <font color="blue">Parameters</font>
    </h3>
    <ul>
      <li>
        <tt>
          <b>A</b>
        </tt>: sparse matrix</li>
      <li>
        <tt>
          <b>sp</b>
        </tt>: sparse matrix</li>
    </ul>
    <h3>
      <font color="blue">Description</font>
    </h3>
    <p>
      <tt>
        <b>sp=spones(A)</b>
      </tt> generates a matrix with the same sparsity
    structure as <tt>
        <b>A</b>
      </tt>, but with ones in the nonzero positions;</p>
    <h3>
      <font color="blue">Examples</font>
    </h3>
    <pre>

A=sprand(10,12,0.1);
sp=spones(A)
B = A~=0
bool2s(B)
 
  </pre>
    <h3>
      <font color="blue">See Also</font>
    </h3>
    <p>
      <a href="sparse.htm">
        <tt>
          <b>sparse</b>
        </tt>
      </a>,&nbsp;&nbsp;<a href="full.htm">
        <tt>
          <b>full</b>
        </tt>
      </a>,&nbsp;&nbsp;<a href="eye.htm">
        <tt>
          <b>eye</b>
        </tt>
      </a>,&nbsp;&nbsp;<a href="speye.htm">
        <tt>
          <b>speye</b>
        </tt>
      </a>,&nbsp;&nbsp;<a href="spzeros.htm">
        <tt>
          <b>spzeros</b>
        </tt>
      </a>,&nbsp;&nbsp;</p>
  </body>
</html>
